#ifndef UART_SEW_H
#define UART_SEW_H

#include "headerconf.h"

/**
*@class ConnectionUSART
*class for USART connection (USART1/2/3)
*connection will established using following parameters
*word length = 8 bit
*stop bits = 1
*parity = no
*hardware flow control = none
*/
class ConnectionUSART
{
	public:
		///Constructor
		ConnectionUSART(uint8_t USARTPort, uint16_t BaudRate);
		///initialises all USART parameter
		void USARTInit(uint16_t BRate, uint8_t USART);
		///sends a single byte
		void Put(uint8_t ch);
		///recieves a single byte
		uint8_t Get(void);
		///sends a single char
		void SendData(unsigned char Data);
		///sends a char array (string)
		void SendData(const char *s);
		///sends an integer
		void SendData(int value);
	private:
		/// the selected port
		uint8_t Port;

};


#endif

